﻿#region summary

// Copyright (c)  YISH. All rights reserved.
// Licensed under the MIT License, See License.txt in the project root for license information.

#endregion

using NSQL.Expressions.Functions;

namespace NSQL.Expressions
{
    /// <summary>
    /// Expression result would be String.
    /// </summary>
    public interface IStringExpression : IExpression
    {
    }

    public static class StringExpressionExtensions
    {
        public static StringExpression AsExpression(this string self) => self;
        public static StringExpression ToExpression(this string self) => self;
        public static IUpperFunction ToUpper(this IStringExpression expr) => new UpperFunction(expr);
        public static ILowerFunction ToLower(this IStringExpression expr) => new LowerFunction(expr);
        public static ILengthFunction Length(this IStringExpression expr) => new LengthFunction(expr);
    }
}